package com.webshopping.service.address;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.webshopping.entry.Address;
import com.webshopping.mapper.AddressMapper;

@Service
public class AddressService {

	@Autowired
	private AddressMapper addMap;
	
	
	public int  addAddress(Address address){
		return addMap.add(address);
	}
	
	
	public int deleteAddress(int id){
		return addMap.delete(id);
	}
	
	public List<Address> queryAddress(Address address){
		return addMap.query(address);
	}
	public List<Address> queryAddById(Address address){
		return addMap.queryAddById(address);
	}
	
	public int changeAdd(Address address){
		
		return addMap.change(address);
	}
	
}
